{extend name="panel/layout" /}
{block name="main"}
<div class="row">
    <div class="col-sm-12">
        <h4 class="page-title">
            <ul class="breadcrumb">
                <li><i class="fa fa-home"></i><a href="/"> 首页</a></li>
                <li><i class="fa fa-desktop"></i><a href="{:url('index')}"> 控制面板</a></li>
                <li class="active">我的QQ列表</li>
            </ul>
        </h4>
    </div>
</div>
<div class="row">
    <div class="col-lg-12">
        <div class="panel panel-primary table-responsive">
            <div class="panel-heading">
                我的QQ列表&nbsp;[<a href="{:url('qqAdd')}" style="color:white"><i class="fa fa-qq"></i>添加QQ</a>]
                <span class="label label-danger pull-right">{:count($qqList)}</span>
            </div>
			<div class="panel-body">
                <form method="get">
                    <input type="hidden" name="action" value="search">
                    <div class="input-group xs-mb-15">
                        <input type="text" placeholder="请输入要搜索的QQ" name="uin"
                               class="form-control text-center"
                               required>
                        <span class="input-group-btn">
                        <button type="submit" class="btn btn-primary">立即搜索</button>
                        </span>
                    </div>
                </form>
            </div>
            <div class="panel-body">
                <div class="col-lg-12 table-responsive">
                    <table class="table table-bordered table-condensed table-hover table-striped table-vertical-center">
                        <thead>
                        <tr>
                            <th width="50">QID</th>
                            <th width="100" class="hidden-xs text-center">头像</th>
                            <th class="text-center">QQ</th>
                            <th class="text-center">状态</th>
                            <th class="text-center">操作</th>
                        </tr>
                        </thead>
                        <tbody>
                        {volist name="qqList" id="qq"}
                        <tr>
                            <td>#{$qq.qid}</td>
                            <td class="hidden-xs text-center">
                                <img src="//q4.qlogo.cn/headimg_dl?dst_uin={$qq.uin}&amp;spec=100"
                                     class="img-circle circle-border m-b-md">
                            </td>
                            <td class="text-center">{$qq.uin}</td>
                            <td class="text-center">{:getQqzt($qq.zt)}</td>
                            <td class="text-center">
								<a class="btn btn-success" href="{:url('qqInfo',['qid'=>$qq.qid])}">代挂详情</a>
                                <a href="{:url('qqAdd')}?qid={$qq.qid}" class="btn btn-warning">更新密码</a>
								<a class="btn btn-danger" href="{:url('qqList')}?qid={$qq.qid}&action=del" onclick="return confirm('你确定要删除此QQ号吗？删除后将停止所有代挂服务');">删除</a>
                            </td>
                        </tr>
                        {/volist}
                        </tbody>
                    </table>
                </div>
            </div>
        </div>
    </div>
</div>
{/block}

